package com.zr.share.enums;

/**
 * @ClassName InquiryStatusEnum
 * @Description TODO
 * @Author Jiakui_Ma
 * @Date 2019/11/14 13:56
 */
public enum InquiryStatusEnum {
    noQuotation("未报价", 0),
    save("已保存", 1),
    submit("已提交", 2),
    audit("已审核", 3),
    cancel("已作废", 4);
    private String name;
    private Integer index;

    InquiryStatusEnum(String name, Integer index) {
        this.name = name;
        this.index = index;
    }

    public static String getName(int index) {
        for (InquiryStatusEnum c : InquiryStatusEnum.values()) {
            if (c.getIndex() == index) {
                return c.name;
            }
        }
        return null;
    }
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getIndex() {
        return index;
    }

    public void setIndex(Integer index) {
        this.index = index;
    }
}
